package com.knight.spring.framework.web.servlet;

import java.lang.reflect.Method;
import java.util.regex.Pattern;

public class KnightHandlerMapping {

    private Object controller;	//保存方法对应的实例
    private Method method;		//保存映射的方法
    private Pattern pattern;    //URL的正则匹配

    public KnightHandlerMapping(Pattern pattern, Object candidateBean, Method method) {
        this.controller = candidateBean;
        this.method = method;
        this.pattern = pattern;
    }

    public Object getController() {
        return controller;
    }

    public Method getMethod() {
        return method;
    }

    public Pattern getPattern() {
        return pattern;
    }
}
